#-*- encoding:utf-8 -*-
import web
from configs import urls

def notfound():
	raise web.seeother('/notfound')

def internalerror():
	raise web.seeother('/internalerror')
	
app = web.application(urls,globals())
app.notfound = notfound
app.internalerror = internalerror

if web.config.get('_session') is None:
	web.config._session = web.session.Session(app, web.session.DiskStore('sessions'),{'loggedin':False})

if __name__ == '__main__' :
	app.run()
else :
	application = app.wsgifunc()
